; * test/lisp/net/shr-tests.el (shr-test/zoom-image): Fix <img> (bug#79041).
authorEli Zaretskii <eliz@gnu.org>
Thu, 17 Jul 2025 16:34:50 +0000 (19:34 +0300)
committerRob Browning <rlb@defaultvalue.org>
Sun, 9 Nov 2025 19:50:49 +0000 (13:50 -0600)
(cherry picked from commit 462a541db904405ede8446c48ba0c71ad41c544d)

README-Debian: The shr-test/zoom image test should now work with libxml2 2.14+
 .
 This upstream patch has been added to fix the problem:
 .
 commit 462a541db904405ede8446c48ba0c71ad41c544d
 Author: Eli Zaretskii <eliz@gnu.org>
 Date:   Thu Jul 17 19:34:50 2025 +0300
 .
    ; * test/lisp/net/shr-tests.el (shr-test/zoom-image): Fix <img> (bug#79041).
Bug: https://debbugs.gnu.org/79041
Bug-Debian: https://bugs.debian.org/1106354

test/lisp/net/shr-tests.el

index 8d66684c96db83d4e202bafdad9043c55f91adba..4978db27df5bfaca2a3a803a624c84416ea7d5bc 100644 (file)
@@ -145,8 +145,8 @@ settings, then once more for each (OPTION . VALUE) pair.")
     (dolist (alt '(nil "" "nothing to see here"))
       (with-temp-buffer
         (ert-info ((format "image with alt=%S" alt))
-          (let ((attrs (if alt (format " alt=\"%s\"" alt) "")))
-            (insert (format "<img src=\"%s\" %s" image-url attrs)))
+          (let ((attrs (if alt (format " alt=\"%s\">" alt) ">")))
+            (insert (format "<img src=\"%s\"%s" image-url attrs)))
           (cl-letf* (;; Pretend we're a graphical display.
                      ((symbol-function 'display-graphic-p) #'always)
                      ((symbol-function 'url-queue-retrieve)